import https from "./https"

class Index extends https{
	
	//轮播题
	getHomePage(){
		return this.request.post('/plugin/site_config/api_index/slideshow',{
			
		})
	}
	
	// 店铺分类
	getStoreType(){
		return this.request.post('/plugin/store/api_public/storeType',{})
	}
	
	// 猜你喜欢的店铺
	getClassifyStore(){
		return this.request.post('/plugin/store/api_public/storeLike',{
			
		})
	}
	
	// 精选店铺
	getStoreList(page){
		return this.request.post('/plugin/store/api_public/storeList',{
			page,
			pagesize: 30,
			selected: true
		})
	}
	
	// 消息列表
	getMsgList(page){
		return this.request.post('/plugin/message/api_in_mail/msgList',{
			type: 'system',
			paginate: 30,
			page,
			proof: uni.getStorageSync('token')
		})
	}
	
	//消息详情
	getMsgDetail(id){
		return this.request.post('/plugin/message/api_in_mail/msgDetail',{
			id,
			proof: uni.getStorageSync('token')
		})
	}
	

	//获取未读消息数量
	getMsgNum(){
		return this.request.post('/plugin/message/api_in_mail/msgNum',{
			type: 'system'
		})
	}
	
	// 消息详情
	getMsgDetail(id){
		return this.request.post('/plugin/message/api_in_mail/msgDetail',{
			id,
			proof: uni.getStorageSync('token')
		})
	}

	//店铺列表
	storeList(page){
		return this.request.post('/plugin/store/api_public/storeList',{
			page,
			pagesize: 30
		})
	}
 
}
export default Index